<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%> 
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <link href="${pageContext.request.contextPath}/pages/css/style1.css" rel="stylesheet" type="text/css" />
    <script src="${pageContext.request.contextPath}/pages/js/jquery1.42.min.js" type="text/javascript"></script>
    <script src="${pageContext.request.contextPath}/pages/js/jquery.js"></script>
    <script src="${pageContext.request.contextPath}/pages/js/jquery.superslide.2.1.1.js" type="text/javascript"></script>
    <title>环保网-首页</title>
</head>
<body>
<div class="wapper_box">
    <div class="header_box"></div>
    <div class="header_box1">
        <div class="header_box2">
            <a class="logo_box" href="${pageContext.request.contextPath}/index/findAll.do"><img src="${pageContext.request.contextPath}/pages/images/huanbaologo.png"/></a>
            <ul class="nav_box">
                <li class="nav_1"><a class="nav_but" href="${pageContext.request.contextPath}/index/findAll.do">网站首页</a></li>
                <li class="nav_1"><a class="nav_but" href="${pageContext.request.contextPath}/news/findAll.do">环保要闻</a></li>
                <li class="nav_1"><a class="nav_but" href="${pageContext.request.contextPath}/paper/findAll.do">环保论文</a></li>
                <li class="nav_1"><a class="nav_but" href="${pageContext.request.contextPath}/laws/findAll.do">环保法规</a></li>
                <li class="nav_1"><a class="nav_but" href="${pageContext.request.contextPath}/device/findAll.do">环保设备</a></li>
                <li class="nav_1"><a class="nav_but" href="${pageContext.request.contextPath}/pages/contant.jsp">联系我们 </a></li>
            </ul>
        </div>

        <script>
            $(".nav_1").mouseenter(function(){
                $(this).find(".nav_slide").slideDown()
            });

            $(".nav_1").mouseleave(function(){
                $(".nav_slide").slideUp()
            });
        </script>
    </div>
    <!--banner部分开始-->
    <div class="banner_box">
        <ul class="banner_pic">
            <li><img src="${pageContext.request.contextPath}/pages/images/t1.jpg" /></li>
            <li><img src="${pageContext.request.contextPath}/pages/images/t3.jpg" /></li>
            <li><img src="${pageContext.request.contextPath}/pages/images/t2.jpg" /></li>

        </ul>
        <a class="prev" href="javascript:void(0)"></a>
        <a class="next" href="javascript:void(0)"></a>
        <div class="num"><ul></ul></div>
    </div>
    <script>
        /*鼠标移过，左右按钮显示*/
        $(".banner_box").hover(function(){
            $(this).find(".prev,.next").fadeTo("show",0.1);
        },function(){
            $(this).find(".prev,.next").hide();
        })
        /*鼠标移过某个按钮 高亮显示*/
        $(".prev,.next").hover(function(){
            $(this).fadeTo("show",0.7);
        },function(){
            $(this).fadeTo("show",0.1);
        })
        $(".banner_box").slide({ titCell:".num ul" , mainCell:".banner_pic" , effect:"fold", autoPlay:true, delayTime:700 , autoPage:true });
    </script>
    <!-- 代码 结束 -->
    <!--banner部分结束-->

    <!--内容开始-->
    <div class="content_box">
        <ul class="content_box_top">
            <li>
                <a href="${pageContext.request.contextPath}/news/findAll.do"><img src="${pageContext.request.contextPath}/pages/images/icon1.png"/></a>
                <h3 class="obj_title">环保要闻</h3>
                <p>环保网<br />重要的新闻</p>
            </li>
            <li>
                <a href="${pageContext.request.contextPath}/paper/findAll.do"><img src="${pageContext.request.contextPath}/pages/images/icon2.png"/></a>
                <h3 class="obj_title">环保论文</h3>
                <p>环保网<br />学术研究成果</p>
            </li>
            <li>
                <a href="${pageContext.request.contextPath}/laws/findAll.do"><img src="${pageContext.request.contextPath}/pages/images/icon3.png"/></a>
                <h3 class="obj_title">环保法规</h3>
                <p>环保网<br />环保相关法律法规</p>
            </li>
            <li>
                <a href="${pageContext.request.contextPath}/device/findAll.do"><img src="${pageContext.request.contextPath}/pages/images/icon4.png"/></a>
                <h3 class="obj_title">环保设备</h3>
                <p>环保网<br />环保设备行业企业</p>
            </li>
        </ul>


        <div class="content_box_bot">
            <ul class="content_box_bot_l">
                <li class="info_news">
                    <div class="info_news_but"><p class="on">环保要闻</p><p>环保法规</p></div>
                    <ul class="info_news_text info_news_text1">                    
                    <c:if test="${!empty newsList}">
						<c:forEach items="${newsList}" var="newsList">
    					 <li><a href="${pageContext.request.contextPath}/newsXq/findOne.do?newsNo=${newsList.newsNo}"><img src="${pageContext.request.contextPath}/pages/images/info_icon1.png"/><p>${newsList.title} 
    					 <span class="date"><fmt:formatDate value="${newsList.posttime}" pattern="yyyy-MM-dd" /></span></p></a></li>
						</c:forEach>
					</c:if>                   
                    </ul>
                    <ul class="info_news_text info_news_text2">
                       <c:if test="${!empty lawsList}">
						<c:forEach items="${lawsList}" var="lawsList">
    					 <li><a href="${pageContext.request.contextPath}/lawsXq/findOne.do?lawsNo=${lawsList.lawsNo}"><img src="${pageContext.request.contextPath}/pages/images/info_icon1.png"/><p>${lawsList.title} <span class="date"><fmt:formatDate value="${lawsList.posttime}" pattern="yyyy-MM-dd" /></span></p></a></li>
						</c:forEach>
					</c:if> 
					 </ul>
                    <script>
                        $(".info_news_but p").each(function(n){
                            $(this).click(function(){
                                $(this).addClass("on").siblings("p").removeClass("on");
                                $(".info_news_text").hide(400).eq(n).show(500);
                            });
                        });
                    </script>
                </li>
            </ul>

            <ul class="content_box_bot_r">
                <p class="jianjie_title">环保设备<span>Device</span></p>
                
                <c:if test="${!empty deviceList}">
						<c:forEach items="${deviceList}" var="deviceList">
    			 <li class="jianjie_box">
                    <div class="jianjie_box1">
                        <img src="${pageContext.request.contextPath}/${deviceList.images}" style="height:60px;width:50px"/>
                        <a href="${pageContext.request.contextPath}/deviceXq/findOne.do?deviceNo=${deviceList.deviceNo}">${deviceList.deviceName}<span>[详情]</span></a>
                    </div>
                </li></c:forEach>
				</c:if> 
                

            </ul>
        </div>

    <!--内容结束-->
    <div class="footer_box"><p>@广西民族师范学院-云玩家项目组<a target="_blank" href="${pageContext.request.contextPath}/login.jsp">   后台入口</a></p></div>

</div>

</body>
</html>